<?php
/**
 * User: xuhong
 * Date: 2018/10/30
 */

namespace extend\mini;


class Template
{
    public function sendTemplate($access_token, $template_body)
    {
        $url = "https://api.weixin.qq.com/cgi-bin/message/wxopen/template/send?access_token={$access_token}";

        $data = json_encode($template_body, JSON_UNESCAPED_UNICODE);
        return postRequest($url, $data);
    }
}